package com.avcompris.common.annotation;

import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.METHOD;
import static java.lang.annotation.ElementType.PARAMETER;
import static java.lang.annotation.RetentionPolicy.RUNTIME;

import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;

/**
 * Use this annotation to flag a method that <em>may</em> return <tt>null</tt>
 * at runtime, or a parameter that <em>may</em> be <tt>null</tt> at runtime. No
 * {@link NullPointerException} will be thrown by the container. <br>
 * <br>
 * Please remember instances must be served by the container to be sure
 * annotations such as <tt>Nullable</tt> will be intercepted and corresponding
 * action fired. E.g. to obtain a new instance of a <tt>DataBean</tt>, use
 * {@link Bakery.getInstance(Class)} instead of <tt>new</tt>.
 * 
 * @author David Andriana Copyright Avantage Compris SARL 2008-2009 ©
 */
@Documented
@Retention(RUNTIME)
@Target({
		PARAMETER, METHOD, FIELD
})
public @interface Nullable {

	// nothing here
}
